from qt_core import *

# PY PUSH BUTTON
# ///////////////////////////////////////////////////////////////
class PyTabs(QWidget):
    def __init__(
            self,
            radius=8,
            border_size=2,
            color="#FFF",
            selection_color="#FFF",
            bg_color="#333",
            bg_color_active="#222",
            context_color="#00ABE8",
            font=''
    ):
        super().__init__()

        # PARAMETERS
        # if text:
        #     self.setText(text)
        # if place_holder_text:
        #     self.setPlaceholderText(place_holder_text)
        # self.setStyleSheet(f"background-color: {bg_color};")
        # SET STYLESHEET
        self.set_stylesheet(
            radius,
            border_size,
            color,
            selection_color,
            bg_color,
            bg_color_active,
            context_color,
            font
        )

    # SET STYLESHEET
    def set_stylesheet(
            self,
            radius,
            border_size,
            color,
            selection_color,
            bg_color,
            bg_color_active,
            context_color,
            font
    ):
        # APPLY STYLESHEET
        style_format = style.format(
            _radius=radius,
            _border_size=border_size,
            _color=color,
            _selection_color=selection_color,
            _bg_color=bg_color,
            _bg_color_active=bg_color_active,
            _context_color=context_color,
            _font= font
        )
        self.setStyleSheet(style_format)
